package com.zxy.ziems.server.weixin;

import com.zxy.btp.security.annotation.IgnoreLogin;
import me.chanjar.weixin.common.error.WxErrorException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class WeChatController {

    @Autowired
    private WeChatService weChatService;


    @IgnoreLogin
    @GetMapping("/sendTest")
    public void sendMessageToUser() throws WxErrorException {
        String modile = "18856898900";
        String content = "测试推送";
        weChatService.sendMessageToUser(modile, content);

    }
}
